Skip to content

gh-116622: Fix testPyObjectPrintOSError on Android#122487

Merged
freakboy3742 merged 3 commits intopython:mainfrom
mhsmith:android-testPyObjectPrintOSError
Jul 31, 2024
Merged

gh-116622: Fix testPyObjectPrintOSError on Android#122487
freakboy3742 merged 3 commits intopython:mainfrom
mhsmith:android-testPyObjectPrintOSError

Conversation

@mhsmith
Copy link
Member

@mhsmith mhsmith commented Jul 30, 2024

This test, which was added in #98749, was failing on Android as follows:

17:43:48.804  W  ======================================================================
17:43:48.804  W  FAIL: testPyObjectPrintOSError (test.test_capi.test_object.PrintTest.testPyObjectPrintOSError)
17:43:48.804  W  ----------------------------------------------------------------------
17:43:48.804  W  Traceback (most recent call last):
17:43:48.804  W    File "/data/user/0/org.python.testbed/files/python/lib/python3.13/test/test_capi/test_object.py", line 103, in testPyObjectPrintOSError
17:43:48.804  W      with self.assertRaises(OSError):
17:43:48.804  W          _testcapi.pyobject_print_os_error(output_filename)
17:43:48.804  W  AssertionError: OSError not raised
17:43:48.804  W
17:43:48.804  W  ----------------------------------------------------------------------

This was caused by a recently-fixed bug in OpenBSD's libc, on which Android's libc is based. Luckily there's a simple workaround.

This PR also addresses the comment in #121595 about it being inconvenient to build all architectures before running the testbed. The build script now allows architectures to be missing, as long as at least one is present.

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants